Ext.onReady(function() {
	
	 var form = new Ext.form.FormPanel({    
     labelAlign: 'right',    
     title: '文件上传',    
     renderTo:'aaa',  
     labelWidth: 60,    
     frame:true,   
  	 url: 'fileUp/fileUp1.action',//fileUploadServlet    
     width: 1040,    
     height:510,   
    fileUpload: true,  
    items: [{    
        xtype: 'textfield',    
        fieldLabel: '文件名',    
        name: 'file',    
        inputType: 'file'//文件类型    
     }],    
    buttons: [{    
        text: '上传',    
        handler: function() {    
        form.getForm().submit({    
       success: function(form, action){    
          Ext.Msg.alert('信息', '文件上传成功！');    
       },    
       failure: function(){    
        Ext.Msg.alert('错误', '文件上传失败');    
      }    
   });    
    }    
  }]    
  });    
});